package com.juc.semaphore.semaphore10;


public class FairRun {
    public static void main(String[] args) {

        MyServiceFair serviceFair = new MyServiceFair();
        MyThreadFair threadFair =  new MyThreadFair(serviceFair);
        threadFair.start();

        MyThreadFair[] threadArray = new MyThreadFair[4];
        for (int i = 0; i < 4; i++) {
            threadArray[i] = new MyThreadFair(serviceFair);
            threadArray[i].start();
        }
    }
}
